package com.wangshouyu.mp.offiaccount.message;

import com.wangshouyu.mp.message.NewsMessage;

import java.util.Objects;

/**
 * @author 王守钰
 * @date 2020年12月07日 13:59
 * @description 客服文章消息
 */
public class KfNewsMessage extends BaseKfMessage{

    /**
     * 文章消息
     */
    private NewsMessage news;

    public NewsMessage getNews() {
        return news;
    }

    public void setNews(NewsMessage news) {
        this.news = news;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        if (!super.equals(o)) return false;
        KfNewsMessage that = (KfNewsMessage) o;
        return Objects.equals(news, that.news);
    }

    @Override
    public int hashCode() {
        return Objects.hash(super.hashCode(), news);
    }

    @Override
    public String toString() {
        return "KfNewsMessage{" +
                "news=" + news +
                '}';
    }
}
